﻿using System;
using System.Collections.Generic;
using System.Text;
using System.Collections;
using System.Xml;

namespace Yuanlin.Business
{
    public class Sections 
    {
        private string name = "";
        private ArrayList section = new ArrayList();

        public string Name
        {
            get
            {
                return name;
            }
            set
            {
                name = value;
            }
        }
        public ArrayList Section
        {
            get
            {
                return section;
            }
            set
            {
                section = value;
            }
        }

        public Sections(XmlNode xmlNode)
        {
            if (xmlNode.Attributes["name"] != null)
            {
                name = xmlNode.Attributes["name"].Value;
            }
            foreach (XmlNode sectionNode in xmlNode.SelectNodes("section"))
            {
                section.Add(new Section(sectionNode.Attributes["name"].Value));
            }
        }
    }
}
